package view;

import utiles.BackGroundPanel;

import javax.imageio.ImageIO;
import javax.swing.*;
import java.awt.*;
import java.io.File;
import java.io.IOException;

/**
 * loginview class
 *
 * @author 小杜
 * @date 2022/11/14
 */

public class LoginView extends ComponentInit {
    @Override
    public Component init() throws IOException {
        JFrame jFrame = new JFrame("登陆界面");

        BackGroundPanel backGroundPanel = new BackGroundPanel(ImageIO.read(new File("C:\\Users\\19723\\IdeaProjects\\GameTest\\src\\Game\\Picture\\背景2.jpeg")));





        jFrame.setVisible(true);
        jFrame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
        jFrame.pack();


        return null;
    }
    public static void Draw(Graphics g){
        g.fillRect(0,0,100,100);
    }
}
